package net.goutalk.glcs.module.organization.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * @title: UpdateDepartmentDto
 * @Author tanyujie
 * @Date: 2022/4/4 16:52
 * @Version 1.0
 */
@Data
public class UpdateDepartmentDto  implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键")
    @NotNull(message = "主键不能为空！")
    private Long id;

    @ApiModelProperty("机构名称")
    @NotNull(message = "机构名称不能为空！")
    @Length(min = 1,max = 10,message = "机构名称最少2个字符，最多20个字符！")
    private String name;

    @ApiModelProperty("机构名称")
    private Long parentId;

    @ApiModelProperty("编码")
    @NotNull(message = "机构编码不能为空！")
    @Length(min = 1,max = 20,message = "机构编码最少2个字符，最多10个字符！")
    private String code;

    @ApiModelProperty("电话")
    @Length(max = 13,message = "电话最多13个字符！")
    private String mobile;

    @ApiModelProperty("邮箱")
    @Email(message = "邮箱格式不正确！")
    @Length(max = 50,message = "邮箱最多50个字符！")
    private String email;

    @ApiModelProperty("主页")
    @Length(max = 50,message = "主页最多50个字符！")
    private String website;

    @ApiModelProperty("地址")
    @Length(max = 250,message = "地址最多50个字符！")
    private String address;

    @ApiModelProperty("排序号")
    private Integer sortCode;

    @ApiModelProperty("备注")
    @Length(max = 250,message = "备注最多50个字符！")
    private String remark;

    @ApiModelProperty("是否启用")
    private Integer enabledMark;


    @ApiModelProperty("组织类别，1：公司，0：部门")
    private Integer departmentType;

}